﻿
IF  EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[sproc_WA_GetDayData]') AND type in (N'P', N'PC'))
    DROP PROCEDURE [dbo].[sproc_WA_GetDayData];
GO
CREATE PROCEDURE [dbo].[sproc_WA_GetDayData] --得到年历数据
	@begintime datetime,
	@endtime   datetime
AS
BEGIN
SET NOCOUNT ON

declare @beginDayValue int;
declare @endDayValue int;

set @beginDayValue = dbo.fn_GetDayValue ( @begintime );
set @endDayValue = dbo.fn_GetDayValue ( @endtime );

select * from dbo.UDS_WorkAttendence_DaySetting where DayValue between @beginDayValue and @endDayValue;

END
GO